import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home'
import PersonInfo from '../views/PersonInfo'
import Position from '../views/Position'
import Company from '../views/Company'
import CompanyPos from '../components/company/CompanyPos'
import CompanyIntro from '../components/company/CompanyIntro'
import WorkFeel from '../components/company/WorkFeel'
import ResumeInfo from '../views/person/ResumeInfo'
import Message from '../views/person/Message'
import Deliver from '../views/person/Deliver'
import Interest from '../views/person/Interest'
import Job from '../views/Job'

Vue.use(VueRouter);


const routes = [
  {
    path: '/',
    name: 'Home',
    component: Home,
  },
  {
    path: '/person',
    name:'个人中心',
    component: PersonInfo,
    children:[
      {
        path: '/resumeInfo',
        name: '简历信息',
        component: ResumeInfo,
      },
      {
        path: '/message',
        name: '消息信息',
        component: Message,
      },
      {
        path: '/deliver',
        name: '投递信息',
        component: Deliver,
      },
      {
        path: '/interest',
        name: '我的关注',
        component: Interest,
      }
    ]
  },
  {
    path: '/position',
    name:'岗位信息',
    component: Position,
  },
  {
    path: '/company',
    name:'企业信息',
    component: Company,
    children:[
      {
        path: '/companyPos',
        name:'招聘职位',
        component: CompanyPos
      },
      {
        path: '/companyIntro',
        name:'公司简介',
        component: CompanyIntro
      },
      {
        path: '/workFeel',
        name:'工作感受',
        component: WorkFeel
      }
    ]
  },
  {
    path: '/job',
    name:'职位信息',
    component: Job,
  },
]

const router = new VueRouter({
  routes
})

export default router
